<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title>vuejs练习</title>
</head>
<body>
    <div id="app">
        <input v-model="newTodo" v-on:keyup.enter="addTodo">
        <ul>
            <li v-for="todo in todos">
                <span>{{todo.text}}</span>
                <button v-on:click="removeTodo($index)">X</button>
            </li>
        </ul>
    </div>
    <script src='http://cdn.jsdelivr.net/vue/1.0.26/vue.min.js'></script>
    <script src="index.js"></script>
</body>
</html>